var rentcarlist = new Vue({
    el: '#rentcarlist',
    data() {
        return {
            rents:[{site:"富华国际",road:"海尔大道",name:"安厦壹品龙腾",amount:"3",area:"153",price:"1400"}
            	],
            	cars:[{departure:"遵义师范学院",destination:"遵义站",time:"6月25日",during:"上午",person:"2"},
                	]
        }
    }
,
mounted: function() {
    //合租
    this.showRent();
    //拼车
    this.showCar();
}, 
methods: {
    showRent:function(){
        var that = this;
        $.ajax({
            url: '   ',		
            type: 'get',
        	contentType: "application/json;charset=UTF-8",
        	dataType: 'json',
        	success: function(msg) {
        	    that.rent=msg.data;		
        	    console.log(msg.data)
        	},error:function () {
        		console.log("合租ing");
        		 }
        		});  
        showCar:function(){
            var that = this;
            $.ajax({
                url: '   ',		
                type: 'get',
            	contentType: "application/json;charset=UTF-8",
            	dataType: 'json',
            	success: function(msg) {
            	    that.car=msg.data;		
            	    console.log(msg.data)
            	},error:function () {
            		console.log("拼车ing");
            		 }
            		}); 
     }	
}

});